package com.leyou.item.service;

import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.cloud.client.circuitbreaker.EnableCircuitBreaker;
import org.springframework.cloud.client.discovery.EnableDiscoveryClient;
import org.springframework.cloud.openfeign.EnableFeignClients;
import org.springframework.cloud.openfeign.FeignClientsConfiguration;
import org.springframework.context.annotation.ComponentScan;
import tk.mybatis.spring.annotation.MapperScan;

@SpringBootApplication
@EnableDiscoveryClient //服务发现
@EnableCircuitBreaker  //开启hystrix熔断器
@ComponentScan(basePackages = {"com.leyou.*"})
@EnableFeignClients(basePackages = {"com.leyou.*.inter"},defaultConfiguration = FeignClientsConfiguration.class)
@MapperScan("com.leyou.item.service.mapper")
public class LeyouItemApplication {
    public static void main(String[] args) {
        SpringApplication.run(LeyouItemApplication.class);
    }
}
